package tmt.usercenter.web.controller.admin;


import com.tmt.datatable.editor.EditorModel;
import com.tmt.datatable.editor.EditorValid;
import com.tmt.datatable.ext.controller.DataTableController;
import com.tmt.datatable.ext.controller.TablePage;
import lombok.Getter;
import lombok.Setter;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import tmt.usercenter.web.common.Const;
import tmt.usercenter.web.domain.AuthResource;
import tmt.usercenter.web.service.AuthResourceService;

import javax.validation.Valid;
import java.util.concurrent.ExecutionException;

@Getter
@Setter
@Controller
@RequestMapping(Const.ADMIN_PATH + "/authresource")
@TablePage(Const.ADMIN_PATH + "/authresource/authresource-index")
public class AuthResourceController extends DataTableController<AuthResource, Long> {

	@Autowired
	private AuthResourceService authResourceService;

	@Override
	public EditorModel<AuthResource> doTableAction(@Valid @EditorValid EditorModel<AuthResource> editor)
			throws ExecutionException, InterruptedException {
		return super.doTableAction(editor);
	}
}
